package ishitong.dataDictionary.controller;

import java.util.List;
import ishitong.common.model.SysCode;

/** @pdOid 0506a225-896b-4f15-8412-5c168774c952 */
public class SysCodeType {
   /** 号牌种类
    * 
    * 
    * @pdOid 6e0e539c-44ad-41e3-91bd-6de63842336d */
   public static final String PLATE_KIND = "013000";
   /** 号牌颜色
    * 
    * @pdOid 4f977b6a-fd1f-482a-ae44-6ac9516b9c1e */
   public static final String PLATE_COLOR = "014000";
   /** 使用性质
    * 
    * 
    * @pdOid 050e3522-946d-465d-b754-6b2404f29eab */
   public static final String USE_NATURE = "032000";
   /** 车辆分类
    * 
    * 
    * @pdOid ad24abcf-f459-46fd-b911-9bbc1da72682 */
   public static final String VEHICLE_SORT = "033000";
   /** 车辆类型
    * 
    * 
    * @pdOid 90ec3d05-0a93-4b8f-98b5-4130889df1d9 */
   public static final String VEHICLE_TYPE = "019000";
   /** 车辆颜色
    * 
    * @pdOid 19858e76-d08e-4d6e-83f0-0de6f0408acb */
   public static final String VEHICLE_COLOR = "016000";
   /** 匹配方式
    * 
    * @pdOid 230bdad5-514a-4a97-a6ab-84e36ab17270 */
   public static final String MATCH_WAY = "";
   /** 审核状态
    * 
    * 
    * 
    * @pdOid 955102a3-c2d4-4650-9cc8-ce4194033401 */
   public static final String AUDIT_STATE = "029200";
   
   /** 根据code和parentcode，获得sysCode
    * 
    * @param listSysCode 
    * @param parentcode 
    * @param code
    * @return
    * 
    * @pdOid 72bb1667-021c-4a78-8412-6c4def5e3225 */
   public SysCode getSysCodeByCodeAndParentcode(List<SysCode> listSysCode, String parentcode, String code) {
    SysCode sysCode = null;
    if (listSysCode != null) {
     for (SysCode sc: listSysCode) {
      if (sc.getCode().equals(code) && sc.getParentcode().equals(parentcode)) {
   	   sysCode = sc;
      }
     }
    }
    return sysCode;
   }

}